<?php /* Smarty version 2.6.18, created on 2008-06-12 23:46:14
         compiled from test.html */ ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>批量图片上传测试</title>
<link href="swfupload/uploader.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="swfupload/swfupload.js"></script>
<script type="text/javascript" src="swfupload/uploadhandlers.js"></script>
<script type="text/javascript">
	var swfu;
	window.onload = function () {
		swfu = new SWFUpload({
			// 后台环境设置
			upload_url: "../websetup.php?controller=websetup&action=upload",	// *相对于SWF文件的路径
			post_params: {"PHPSESSID": "<?php echo '<?php'; ?>
 echo session_id(); <?php echo '?>'; ?>
"},

			// 文件上传限制
			file_size_limit : "2048",	// 2MB
			file_types : "*.jpg",
			file_types_description : "JPEG Images",
			file_upload_limit : "0",    // 用户能够一次性上传的文件总数，0为不限制

			// 动作处理程序定义 - 下面的程序已经在 uploadhandlers.js 中定义
			// 动作处理程序不是 SWFUpload 的一部分，是帮助网站处理 SWFUpload 返回的动作的程序
			file_queue_error_handler : fileQueueError,
			file_dialog_complete_handler : fileDialogComplete,
			upload_progress_handler : uploadProgress,
			upload_error_handler : uploadError,
			upload_success_handler : uploadSuccess,
			upload_complete_handler : uploadComplete,

			// Flash Settings
			flash_url : "swfupload/swfupload_f9.swf",	// 入口程序到SWF的相对路径

			custom_settings : {
				upload_target : "divFileProgressContainer"
			},
			
			// Debug Settings
			debug: false
		});
	}
</script>
</head>
<body>


<div style="margin: 30px 10px;">
	<div>
		<form>
			<button id="btnBrowse" type="button" style="padding: 5px;" onclick="swfu.selectFiles(); this.blur();"><img src="swfupload/images/page_white_add.png" style="padding-right: 3px; vertical-align: bottom;">Select Images <span style="font-size: 7pt;">(2 MB Max)</span></button>
		</form>
	</div>
	<div id="divFileProgressContainer" style="height: 75px;"></div>
	<div id="thumbnails"></div>
</div>

</body>
</html>